/* creat.c
 *	Simple program to test whether creating program works.
 *	
 *	Creates a file if all is well
 *
 */

#include "syscall.h"

char buff[100];

int
main(int argc, char** argv)
{
    creat(argv[1]);
    int id = open(argv[1]);
    buff[0] = 'H';
    buff[1] = 'e';
    buff[2] = 'l';
    buff[3] = 'l';
    buff[4] = 'o';
    buff[5] = ' ';
    buff[6] = 'W';
    buff[7] = 'o';
    buff[8] = 'r';
    buff[9] = 'l';
    buff[10] = 'd';
    buff[11] = ' ';
    int i;
    for (i = 0;i < 200000;i++)
        write(id,buff,11);
    write(id,buff,11);
}

